home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / std / c / 487 < prev    next >
Internet Message Format  |  1996-08-06  |  1KB

  1. Path: io.com!not-for-mail
  2. From: jamshid@io.com (Jamshid Afshar)
  3. Newsgroups: comp.std.c
  4. Subject: Multibyte and wide-character support
  5. Date: 4 Mar 1996 02:26:56 -0600
  6. Organization: Illuminati Online, Austin, Texas, USA
  7. Message-ID: <4he9gg$m9l@pentagon.io.com>
  8. NNTP-Posting-Host: pentagon.io.com
  9.  
  10.  
  11. Is there an easy way to test if a multibyte string contains only
  12. singlebyte characters and thus can be passed to a function expecting a
  13. "regular" char*?  Is "if (strlen(mbs)==mblen(mbs))" a valid test and
  14. is there anything better?
  15.  
  16. Why aren't there wchar_t versions of functions like atoi() strtod()?
  17. Do they just have to be converted to multibyte strings, and do atoi(),
  18. etc. work with multibyte strings?
  19.  
  20. Btw, VC++4's docs say that if mbstowcs()'s wchar_t* destination
  21. argument is NULL then the function doesn't do a conversion of the
  22. multibyte string; it just returns the size needed to store the
  23. multibyte string.  Accepting a NULL first argument is not required by
  24. Standard C, is it?  Also, the VC++4 docs seem to indicate fputws(), a
  25. wchar_t version of fputs(), is "ANSI" compatible.  Standard C doesn't
  26. actually specify any wide-character i/o functions, does it?
  27.  
  28. Thanks,
  29. Jamshid Afshar
  30. jamshid@io.com
  31.  
  32.